<?php
//测试控制器类
class IndexController extends Controller{
    //动作方法
    public function index(){
        //显示视图
        $this->display();
    }
    public function add(){
    	$Model = K('News');
    	if($Model->create()){
    		if($Model->add()){
    			$this->success('入库成功。。');
    		}
    	}else{
    		$this->error($Model->error);
    	}
    }
}
